package com.yunao.commons.enums;

import lombok.Getter;

@Getter
public enum ResultEnum {
    INNER_ERROR(-2,"系统错误"),
    EORROR(-1,"服务端错误"),
    PARAM_ERROR(1,"参数不正确"),
    CODE_ERROR(9,"验证码错误"),
    USER_EXIST(8,"用户已存在"),
    USER_NOT_EXIST(10,"用户不存在"),
    PRODUCT_STOCK_ERROR(11,"库存不正确"),
    ORDER_NOT_EXIST(12,"订单不存在"),
    ORDERDETAIL_NOT_EXIST(13,"订单详情不存在"),
    ORDER_STATUS_ERROR(14,"订单状态不正确"),
    ORDER_UPDATE_FAIL(15,"更新订单失败"),
    ORDER_DETAIL_EMPTY(16,"订单详情为空"),
    ORDER_PAY_STATUS_ERROR(17,"订单支付状态不正确"),
    CART_EMPTY(18,"购物车为空"),
    ORDER_OWNER_ERROR(19,"订单不属于当前用户"),
    SUBJECT_NOT_EXIST(20,"专题不存在"),
    PASSWORD_ERROR(21,"密码错误"),
    ACCOUNT_OUT_DATE(22,"账户已过期，请联系管理员"),
    ORGAN_OUT_DATE(23,"组织已过期，请联系管理员"),
    REPORT_NAME_ERROR(30,"标题名称不能为空"),
    REPORT_MANNER_ERROR(31,"报告类型为空"),
    REPORT_ARRE_ERROR(32,"接收人为空"),
    REPORT_USER_ERROR(33,"缺少用户ID"),
    REPORT_EMAIL_ERROR(34,"添加失败，报告发送地址错误！"),
    REPORT_ADDMANNER_ERROR(35,"添加失败，自动报告类型异常！"),
    ALONEREPORT_ID_ERROR(36,"添加失败，ID为空或不存在该ID！"),
    ALONEREPORT_NAME_ERROR(37,"专题名称重复"),
    ALONEREPORT_NAMESHORT_ERROR(38,"标题名称最短支持 2 个字符！"),
    ALONEREPORT_NAMELONG_ERROR(39,"标题名称最长支持 15 个字符！"),
    ALONEREPORT_KEYWORDCHAR_ERROR(40,"关键词/排除词中不能有特殊字符"),
    ALONEREPORT_KEYWORD_ERROR(41,"请用英文符号"),
    ALONEREPORT_KEYWORD_AND_RWORD_ERROR(42,"关键词和排除词不能相同"),
    ALONEREPORT_KEYWORD_NULL_ERROR(43,"关键词不能为空"),
    ALONEREPORT_REMWORD_REPEAT_ERROR(44,"排除词重复"),
    ALONEREPORT_KEYWORD_MAY_ERROR(45,"关键词可能存在异常"),
    ALONEREPORT_WEBATTR_ERROR(46,"最多只能添加五个网站"),
    ALONEREPORT_WEBATTR_REPEAT_ERROR(47,"网站重复"),
    ALONEREPORT_WEBATTR_FORMAT_ERROR(48,"请输入正确网站"),
    ALONEREPORT_WEBATTR_ONE_ERROR(49,"只能添加一个地址"),
    ALONEREPORT_MANNER_ERROR(50,"请选择报告类型"),
    ALONEREPORT_EMAIL_ERROR(51,"请填写报告发送地址"),
    ALONEREPORT_ADDR_ERROR(52,"请填写地址"),
    WECHAT_QRCODE_ERROR(53,"获取微信二维码失败"),
    WECHAT_ACCESS_TOKEN_ERROR(54,"微信access_token不可用"),
    WECHAT_PUSH_ERROR(55,"微信推送失败"),
    ALARM_ADDRS_ERROR(56,"预警地址错误"),
    TOKEN_ERROR(401,"token失效,请重新登录"),
    EMAIL_ADDR_ERROR(57,"邮箱格式有误"),
    REPORT_EMPTY(58,"报告为空"),
    IMREPORT_ERROR(59,"报告ID为空或报告ID错误"),
    ARTICLE_EMPTY(60,"请选择删除文章"),
    ARTICLE_EXIET(61,"该文章已关注"),
    EMAIL_NOT_EXIET(62,"请填写邮箱地址"),
    USER_ROLE_ERROR(63,"用户权限不足"),
    ORGAN_NOT_EXIET(64,"请选择组织"),
    FUNCTIONS_NULL(65,"ID不存在"),
    ;

    private Integer code;
    private String message;

    ResultEnum(Integer code, String message) {
        this.code = code;
        this.message = message;
    }
}
